package spring.cloud.tasks.executor.exception;


/**
 * 分布式作业抛出的异常基类
 */
public class JobException extends RuntimeException {

    private static final long serialVersionUID = -5323792555332165319L;

    /**
     * @param errorMessage if the args array are not empty then should be the format of error message; otherwise, it is the error message.
     * @param args         Arguments referenced by the format specifiers in the format string
     */
    public JobException(final String errorMessage, final Object... args) {
        super(String.format(errorMessage, args));
    }

    public JobException(final Exception cause) {
        super(cause);
    }

    public JobException(Throwable cause) {
        super(cause);
    }

}
